package gdut.jmxywz.action;



import gdut.jmxywz.been.Dissertation;
import gdut.jmxywz.been.DissertationFile;
import gdut.jmxywz.been.Teacher;
import gdut.jmxywz.util.PageModel;

import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.InputStream;
import java.text.SimpleDateFormat;
import java.util.Iterator;
import java.util.List;
import java.util.Random;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import jxl.Cell;
import jxl.Sheet;
import jxl.Workbook;
import jxl.write.Label;
import jxl.write.WritableSheet;
import jxl.write.WritableWorkbook;

import org.apache.struts2.ServletActionContext;

import com.opensymphony.xwork2.ActionContext;


public class DissertationAction extends BaseAction{
	private  static final String  TEACHER_SESSION_KEY = "teacherSessionKey";
	private Teacher  teacher;
	
	private Dissertation dissertation;
	 private PageModel pageModel;
	 private int disId;
	 
		/***************分页*****************/
		private int currentPage=1;
		
		private int pageSize=5;
		
		//
		private String nextPage;
		
		/***************检索*****************/
		//private String searchSelect="";
		
		private String like="";
		
		//private String searchValue="";
		private String where_search="";
		private String where_value="";

		/**************文件上传****************/
		private List<String> files_content;
		private List<File> upload_file;       
		

		private List<String> upload_fileContentType;
		private List<String> upload_fileFileName;
		private String   savePath;
		private List<DissertationFile> dissertationFile ;
		
		/**************excel表导出导入****************/
		private File excelFile;
		private String excelFileContentType;
		private boolean checkbox;
		
		
		
		
		/***************增加*****************/
		 public String add() throws Exception{
			 teacher = (Teacher)ActionContext.getContext().getSession().get(TEACHER_SESSION_KEY);
			 dissertation.setTeacherByEditer(teacher);
	boolean bool=this.getCommonService().saveObject(dissertation);
	    	 
			 if(upload_file!=null)
			
					for(int i=0;i<upload_file.size();i++){//控制上传部分
						String extend_name=getUpload_fileFileName().get(i);
//						System.out.println(extend_name);
						int extend_name_int=extend_name.lastIndexOf(".");//截取扩展名
						extend_name=extend_name.substring(extend_name_int);
									
						java.text.DateFormat df = new java.text.SimpleDateFormat("yyyyMMddHHmmss") ;//生成时间用于重命名文件
					   String datestr = df.format(new java.util.Date()) ;
					   Random rand = new Random();//生成随机数
					   int ram = rand.nextInt(500);
						String ram_str = String.valueOf(ram);
						for(int i_i=0; ram_str.length()<6;i_i++){
							ram_str="0"+ram_str;
						}
						

						
						
						String root = ServletActionContext.getRequest().getRealPath(
								"/accessories/dissertation/");//获得文件在服务器的绝对路径
						
						extend_name=datestr+ram_str+extend_name;//合成文件名    时间+随机数+扩展名
//						System.out.println("----文件名-:---"+extend_name+"--------------");
						 savePath=root+"\\"+extend_name;
						
//							System.out.println("----服务器保存路径-:---"+savePath+"--------------");
						 
						String fn=savePath ;
						FileOutputStream fos=new  FileOutputStream(fn);
						
						InputStream fis=new FileInputStream(upload_file.get(i));
						byte[] buffer=new byte[8192];
						int len=0;
						while((len=fis.read(buffer))>0){
						fos.write(buffer,0,len);
						
						}
//						fos.close();
//						fis.close();
						
						DissertationFile afiles=new DissertationFile();
									
						
//						System.out.println();
//						System.out.println("----------第--"+(i+1)+"--文件--------------");
//						System.out.println("----服务器保存路径-:---"+savePath+"--------------");
//						System.out.println("--------文件名:"+upload_fileFileName.get(i)+"--------------");
//						System.out.println("--------文件说明:"+files_content.get(i)+"--------------");
						
						afiles.setDissertationFileUrl("/accessories/dissertation/"+extend_name);
						afiles.setDissertationFileName(upload_fileFileName.get(i));
						afiles.setDissertationFileContext(files_content.get(i));
						afiles.setDissertation(dissertation);	
			
						//在插入附件表
						boolean b2=this.getCommonService().saveObject(afiles);
				
//				文件上传处理结束
				
		     	}

			 if(bool)
				 return SUCCESS;
			 else
				 return "error";
		 }
	 
	 
	 /***************show*****************/
		public String show()throws Exception{
			
			String hql=" from Dissertation where auditing != 0";
			hql = hql +" order by disId desc,auditing desc";
			pageModel=this.getCommonService().findPage(hql, null, currentPage, pageSize,"DissertationShow.action","");
//			scientificInfo=(Info)pageModel.getList().get(0);
//			System.out.println("============================"+scientificInfo.getInfoTitle());
			return SUCCESS;
			
		}
		
     //最新列表
      public String showforlist()throws Exception{
    	    String hql=" from Dissertation where auditing != 0";
			hql = hql +" order by disId desc,auditing desc";
			pageModel=this.getCommonService().findPage(hql, null, currentPage, pageSize,"DissertationList.action","");
//			scientificInfo=(Info)pageModel.getList().get(0);
//			System.out.println("============================"+scientificInfo.getInfoTitle());
			return SUCCESS;
			
		}
		
		
		/***************查找*****************/
		public String search() throws Exception {
			// TODO Auto-generated method stub
			String hql="from Dissertation where auditing != 0";
			

			 String[] parem = null;
	    	  
	    	  String  search_parameter = "";
	    	  String en_where_value="";
	    	  
	    	  //
	    	  String searchValue1=where_value;
	    	  //
				HttpServletRequest request = ServletActionContext.getRequest();
				where_value=new String(request.getParameter("where_value").getBytes("ISO-8859-1"),"UTF-8");
				//
          if(!"".equals(where_value)&&where_value!=null){
	    		  
	    		  en_where_value=java.net.URLEncoder.encode(where_value, "utf-8");//URL编码转换
	    		  System.out.println("++++-- "+where_value);
	    		  
	    		  if (like.equals("like")) {
	    			  hql = hql + "  and " + where_search + " like '%"+ searchValue1 + "%' ";
	  				//hql = hql + "  and sc." + where_search + " like '%"+ searchValue1 + "%' ";
	  			} else {
	  				hql = hql + "  and " + where_search + " ='"+ searchValue1 + "' ";
	  				//hql = hql + "  and sc." + where_search + " ='"+ searchValue1 + "' ";
	  			}
	    		  
	    	  }
	    	  
              hql = hql +" order by disId desc,auditing desc";
	    	  
	    	  //查询条件
	    	  
	    	  search_parameter="&where_search="+ where_search+"&like="+like+"&where_value="+en_where_value;
	    	  
	    	  pageModel = new PageModel();
	    	  
	    	  pageModel=this.getCommonService().findPage(hql, parem, currentPage, pageSize, "DissertationSearch.action",search_parameter);
			
			
		
			return SUCCESS;
			
			
		}

		
		
		
		/***************详细*****************/
		public String detail() throws Exception {
			// TODO Auto-generated method stub
			String hql="from DissertationFile where DisId="+disId;
			
			dissertationFile=this.getCommonService().findListByHql(hql, null);
			dissertation=(Dissertation)this.getCommonService().findByIntId(disId, "gdut.jmxywz.been.Dissertation");
			if(dissertation==null)
				return "error";
			else
				return SUCCESS;
		}

		
		
		
		
		/***************管理员更新预处理*****************/
		public String preUpdate() throws Exception {
			 teacher = (Teacher)ActionContext.getContext().getSession().get(TEACHER_SESSION_KEY);

			// TODO Auto-generated method stub
			dissertation=(Dissertation)this.getCommonService().findByIntId(disId, "gdut.jmxywz.been.Dissertation");
			dissertation.setTeacherByAssessor(teacher);
			String hql2="from DissertationFile where disId="+disId;
//			System.out.println(hql2);
			dissertationFile=this.getCommonService().findListByHql(hql2, null);
			
			
			if(dissertation==null)
				return "error";
			else
				return SUCCESS;
		}
		
		/***************非管理员更新预处理*****************/
		public String preUpdateSelf() throws Exception {
			 teacher = (Teacher)ActionContext.getContext().getSession().get(TEACHER_SESSION_KEY);

			// TODO Auto-generated method stub
			dissertation=(Dissertation)this.getCommonService().findByIntId(disId, "gdut.jmxywz.been.Dissertation");
			if(!dissertation.getTeacherByEditer().getTeacherId().equals(teacher.getTeacherId())){
				
				System.out.println("没有修改的权限");
				
				return "error";
			}
			if(!"0".equals(dissertation.getAuditing())){
		   		  
		   		System.out.println("已通过审核，不能在修改！");
		   		
		   		return "error";
		   	  }
			
			String hql2="from DissertationFile where disId="+disId;
//			System.out.println(hql2);
			dissertationFile=this.getCommonService().findListByHql(hql2, null);
			
			
			if(dissertation==null)
				return "error";
			else
				return SUCCESS;
		}
		
		
		
		/***************更新*****************/
		public String update() throws Exception {
			
			
			Dissertation dissertation2=(Dissertation)this.getCommonService().findByIntId(dissertation.getDisId(), "gdut.jmxywz.been.Dissertation");
			dissertation2.setAssessorInfo(dissertation.getAssessorInfo());
			dissertation2.setAuthor1(dissertation.getAuthor1());
			dissertation2.setAuthor2(dissertation.getAuthor2());
			dissertation2.setAuthor3(dissertation.getAuthor3());
			dissertation2.setCatalog(dissertation.getCatalog());
			dissertation2.setCn(dissertation.getCn());
			dissertation2.setColloquium(dissertation.getColloquium());
			dissertation2.setCorePeriodical(dissertation.getCorePeriodical());
			dissertation2.setDocumentCode(dissertation.getDocumentCode());
			dissertation2.setEi(dissertation.getEi());
			dissertation2.setForeignPage(dissertation.getForeignPage());
			dissertation2.setFullTextCopy(dissertation.getFullTextCopy());
			dissertation2.setIntergral(dissertation.getIntergral());
			dissertation2.setIsbn(dissertation.getIsbn());
			dissertation2.setIssn(dissertation.getIssn());
			dissertation2.setIssue(dissertation.getIssue());
			dissertation2.setIstp(dissertation.getIstp());
			dissertation2.setLocal(dissertation.getLocal());
			dissertation2.setPage(dissertation.getPage());
			dissertation2.setPublication(dissertation.getPublication());
			dissertation2.setPublishCn(dissertation.getPublishCn());
			dissertation2.setPublishYear(dissertation.getPublishYear());
			dissertation2.setRoll(dissertation.getRoll());
			dissertation2.setSci(dissertation.getSci());
			dissertation2.setSource(dissertation.getSource());
			dissertation2.setTitle(dissertation.getTitle());
			dissertation2.setType(dissertation.getType());
			dissertation2.setTo2author(dissertation.getTo2author());
			
			
			// TODO Auto-generated method stub
			boolean bl=this.getCommonService().updateObject(dissertation2);
			
			 if(upload_file!=null)
					
					for(int i=0;i<upload_file.size();i++){//控制上传部分
						String extend_name=getUpload_fileFileName().get(i);
//						System.out.println(extend_name);
						int extend_name_int=extend_name.lastIndexOf(".");//截取扩展名
						extend_name=extend_name.substring(extend_name_int);
									
						java.text.DateFormat df = new java.text.SimpleDateFormat("yyyyMMddHHmmss") ;//生成时间用于重命名文件
					   String datestr = df.format(new java.util.Date()) ;
					   Random rand = new Random();//生成随机数
					   int ram = rand.nextInt(500);
						String ram_str = String.valueOf(ram);
						for(int i_i=0; ram_str.length()<6;i_i++){
							ram_str="0"+ram_str;
						}
						

						
						
						String root = ServletActionContext.getRequest().getRealPath(
								"/accessories/dissertation/");//获得文件在服务器的绝对路径
						
						extend_name=datestr+ram_str+extend_name;//合成文件名    时间+随机数+扩展名
//						System.out.println("----文件名-:---"+extend_name+"--------------");
						 savePath=root+"\\"+extend_name;
						
//							System.out.println("----服务器保存路径-:---"+savePath+"--------------");
						 
						String fn=savePath ;
						FileOutputStream fos=new  FileOutputStream(fn);
						
						InputStream fis=new FileInputStream(upload_file.get(i));
						byte[] buffer=new byte[8192];
						int len=0;
						while((len=fis.read(buffer))>0){
						fos.write(buffer,0,len);
						
						}
						DissertationFile afiles=new DissertationFile();
									
						
						afiles.setDissertationFileUrl("/accessories/dissertation/"+extend_name);
						afiles.setDissertationFileName(upload_fileFileName.get(i));
						afiles.setDissertationFileContext(files_content.get(i));
						afiles.setDissertation(dissertation);	
			
						//在插入附件表
						boolean b2=this.getCommonService().saveObject(afiles);
				
//				文件上传处理结束
				
		     	}

			
			if(bl)
				return SUCCESS;
			else
				return "error";
		}
		
		
		
		
		/***************删除*****************/
		public String delete() throws Exception {
			  teacher = (Teacher)ActionContext.getContext().getSession().get(TEACHER_SESSION_KEY);

			// TODO Auto-generated method stub
			
			dissertation=(Dissertation)this.getCommonService().findByIntId(disId, "gdut.jmxywz.been.Dissertation");
             
			
			
			if(dissertation!=null){
				
				
				String hql="from DissertationFile where disId="+disId;
		         
				Dissertation dissertation = new Dissertation();
			         
				dissertation =(Dissertation) this.getCommonService().findByIntId(disId, "gdut.jmxywz.been.Dissertation");
			   	  
			         //删除服务器上的附件
			   	  
			   	    List fileList = this.getCommonService().findListByHql(hql, null);
			   	  
			   	    Iterator iter = fileList.iterator();
			   	   
			   	    while(iter.hasNext()){
			   		  
			   	    	DissertationFile dissertationFile = (DissertationFile)iter.next();
			   		  
			   		  String path = ServletActionContext.getRequest().getRealPath("/");
			   		  
			   		  path = path + dissertationFile.getDissertationFileUrl();
			   		  
			   		  System.out.println("======="+path);
			   		  
			   		  this.getCommonService().deleteObject(dissertationFile);
			   		  
			   		  this.deleteFile(path);
			   		  
			   		  System.out.println("===文件删除===");
			   	    }
			   		  
			   		boolean bl=this.getCommonService().deleteObject(dissertation);//删除科研著作
			   		
			   		if(bl)
						return SUCCESS;
					else
						return "error";
			   	  }
				
				
				
				else
					return "error";
			
		}
		
		/***************非管理员删除*****************/
		public String deleteSelf() throws Exception {
			 teacher = (Teacher)ActionContext.getContext().getSession().get(TEACHER_SESSION_KEY);

			// TODO Auto-generated method stub
			
			dissertation=(Dissertation)this.getCommonService().findByIntId(disId, "gdut.jmxywz.been.Dissertation");
             
			//判断是否可以删除
	  	    if(!dissertation.getTeacherByEditer().getTeacherId().equals(teacher.getTeacherId())){
				
				System.out.println("没有删除的权限");
				
				return "error";
			}
			if(!"0".equals(dissertation.getAuditing())){
		   		  
		   		System.out.println("已通过审核，不能在修改！");
		   		
		   		return "error";
		   	  }
			
			if(dissertation!=null){
				
				
				String hql="from DissertationFile where disId="+disId;
		         
				Dissertation dissertation = new Dissertation();
			         
				dissertation =(Dissertation) this.getCommonService().findByIntId(disId, "gdut.jmxywz.been.Dissertation");
			   	  
			         //删除服务器上的附件
			   	  
			   	    List fileList = this.getCommonService().findListByHql(hql, null);
			   	  
			   	    Iterator iter = fileList.iterator();
			   	   
			   	    while(iter.hasNext()){
			   		  
			   	    	DissertationFile dissertationFile = (DissertationFile)iter.next();
			   		  
			   		  String path = ServletActionContext.getRequest().getRealPath("/");
			   		  
			   		  path = path + dissertationFile.getDissertationFileUrl();
			   		  
			   		  System.out.println("======="+path);
			   		  
			   		  this.getCommonService().deleteObject(dissertationFile);
			   		  
			   		  this.deleteFile(path);
			   		  
			   		  System.out.println("===文件删除===");
			   	    }
			   		  
			   		boolean bl=this.getCommonService().deleteObject(dissertation);//删除科研著作
			   		
			   		if(bl)
						return SUCCESS;
					else
						return "error";
			   	  }
				
				
				
				else
					return "error";
			
		}
		
		 /***
		    *  deleteFile  从服务器上删除附件
		    * @param sPath
		    * @return
		    */
			
			public  boolean deleteFile(String sPath) {   
				boolean  flag = false;   
				File   file = new File(sPath);   
			    // 路径为文件且不为空则进行删除   
			    if (file.isFile() && file.exists()) {   
			        file.delete();   
			        System.out.println("---成功从服务器删除文件---");
			        flag = true;   
			    }   
			    return flag;   
			}  
		
		
		/***************show审核信息列表*****************/
		public String auditingShow()throws Exception{
			 teacher = (Teacher)ActionContext.getContext().getSession().get(TEACHER_SESSION_KEY);

			String hql=" from Dissertation ";
			 hql = hql +"  order by auditing asc ,disId desc";
			pageModel=this.getCommonService().findPage(hql, null, currentPage, pageSize,"DissertationAuditingShow.action","");
		
			
			return SUCCESS;
		}
		/***************show非管理员信息列表*****************/
		public String selfShow()throws Exception{
			 teacher = (Teacher)ActionContext.getContext().getSession().get(TEACHER_SESSION_KEY);
			 String hql=" from Dissertation where teacherByEditer.teacherId="+teacher.getTeacherId();
			 hql = hql +"  order by auditing asc ,disId desc";
		
			
			pageModel=this.getCommonService().findPage(hql, null, currentPage, pageSize,"DissertationSelfShow.action","");			
			return SUCCESS;
		}
		//
		public String selfShow1()throws Exception{
			
			 teacher = (Teacher)ActionContext.getContext().getSession().get(TEACHER_SESSION_KEY);
			 String hql=" from Dissertation  ";
			 //
			 String[] parem = null;
	    	  
	    	  String  search_parameter = "";
	    	  String en_where_value="";
	    	  
	    	 
				HttpServletRequest request = ServletActionContext.getRequest();
				where_value=new String(request.getParameter("where_value").getBytes("ISO-8859-1"),"UTF-8");
				 //
		    	  String searchValue1=where_value;
		    	  //
				//
         if(!"".equals(where_value)&&where_value!=null){
	    		  
	    		  en_where_value=java.net.URLEncoder.encode(where_value, "utf-8");//URL编码转换
	    		  System.out.println("++++-- "+where_value);
	    		  
	    		  if (like.equals("like")) {
	    			  hql = hql + "  where " + where_search + " like '%"+ searchValue1 + "%' ";
	  				//hql = hql + "  and sc." + where_search + " like '%"+ searchValue1 + "%' ";
	  			} else {
	  				hql = hql + "  where " + where_search + " ='"+ searchValue1 + "' ";
	  				//hql = hql + "  and sc." + where_search + " ='"+ searchValue1 + "' ";
	  			}
	    		  
	    	  }
	    	  
         hql = hql +"  order by auditing asc ,disId desc";	
	    	  
	    	  //查询条件
	    	  
	    	  search_parameter="&where_search="+ where_search+"&like="+like+"&where_value="+en_where_value;
	    	  
	    	  pageModel = new PageModel();
	    	  
	    	  pageModel=this.getCommonService().findPage(hql, parem, currentPage, pageSize, "DissertationSelfShow1.action",search_parameter);
			
			 
			 
			 
				
			return SUCCESS;
		}
		
		public String selfShow2()throws Exception{
			
			 String hql=" from Dissertation ";		
			
			 String[] parem = null;
	    	  
	    	  String  search_parameter = "";
	    	  String en_where_value="";
	    	  
	    	 
				HttpServletRequest request = ServletActionContext.getRequest();
				where_value=new String(request.getParameter("where_value").getBytes("ISO-8859-1"),"UTF-8");
				 //
		    	  String searchValue1=where_value;
		    	  //
				//
        if(!"".equals(where_value)&&where_value!=null){
	    		  
	    		  en_where_value=java.net.URLEncoder.encode(where_value, "utf-8");//URL编码转换
	    		  System.out.println("++++-- "+where_value);
	    		  
	    		  if (like.equals("like")) {
	    			  hql =hql+"where "+where_search+" like '%"+searchValue1+"%'";
	  				//hql = hql + "  and sc." + where_search + " like '%"+ searchValue1 + "%' ";
	  			} else {
	  				hql = hql +"where  "+where_search+" = '"+searchValue1+"'";
	  				//hql = hql + "  and sc." + where_search + " ='"+ searchValue1 + "' ";
	  			}
	    		  
	    	  }
	    	  
        hql = hql +"  order by auditing asc ,disId desc";	
	    	  
	    	  //查询条件
	    	  
	    	  search_parameter="&where_search="+ where_search+"&like="+like+"&where_value="+en_where_value;
	    	  
	    	  pageModel = new PageModel();
	    	  
	    	  pageModel=this.getCommonService().findPage(hql, parem, currentPage, pageSize, "DissertationList1.action",search_parameter);
			
	    	 
			return SUCCESS;
		}
		
		
		
		/***************Search审核列表*****************/		
		public String searchAuditing() throws Exception {
			// TODO Auto-generated method stub
			String hql="from Dissertation";
			
			
			 String[] parem = null;
	    	  
	    	  String  search_parameter = "";
	    	  String en_where_value="";
	    	  
	    	  //
	    	  String searchValue1=where_value;
	    	  //
				HttpServletRequest request = ServletActionContext.getRequest();
				where_value=new String(request.getParameter("where_value").getBytes("ISO-8859-1"),"UTF-8");
				//
       if(!"".equals(where_value)&&where_value!=null){
	    		  
	    		  en_where_value=java.net.URLEncoder.encode(where_value, "utf-8");//URL编码转换
	    		  System.out.println("++++-- "+where_value);
	    		  
	    		  if (like.equals("like")) {
	    			  hql = hql + "  where " + where_search + " like '%"+ searchValue1 + "%' ";
	  				//hql = hql + "  and sc." + where_search + " like '%"+ searchValue1 + "%' ";
	  			} else {
	  				hql = hql + "  where " + where_search + " ='"+ searchValue1 + "' ";
	  				//hql = hql + "  and sc." + where_search + " ='"+ searchValue1 + "' ";
	  			}
	    		  
	    	  }
	    	  
       hql = hql +"  order by auditing asc ,disId desc";	
	    	  
	    	  //查询条件
	    	  
	    	  search_parameter="&where_search="+ where_search+"&like="+like+"&where_value="+en_where_value;
	    	  
	    	  pageModel = new PageModel();
	    	  
	    	  pageModel=this.getCommonService().findPage(hql, parem, currentPage, pageSize, "DissertationSearchAuditing.action",search_parameter);
			
			
			return SUCCESS;
		}
		
		//
		public String searchAuditing1() throws Exception {
			// TODO Auto-generated method stub
			String hql="from Dissertation";
			
			
			 String[] parem = null;
	    	  
	    	  String  search_parameter = "";
	    	  String en_where_value="";
	    	  
	    	 
				HttpServletRequest request = ServletActionContext.getRequest();
				where_value=new String(request.getParameter("where_value").getBytes("ISO-8859-1"),"UTF-8");
				 //
		    	  String searchValue1=where_value;
		    	  //
				//
      if(!"".equals(where_value)&&where_value!=null){
	    		  
	    		  en_where_value=java.net.URLEncoder.encode(where_value, "utf-8");//URL编码转换
	    		  System.out.println("++++-- "+where_value);
	    		  
	    		  if (like.equals("like")) {
	    			  hql = hql + "  where " + where_search + " like '%"+ searchValue1 + "%' ";
	  				//hql = hql + "  and sc." + where_search + " like '%"+ searchValue1 + "%' ";
	  			} else {
	  				hql = hql + "  where " + where_search + " ='"+ searchValue1 + "' ";
	  				//hql = hql + "  and sc." + where_search + " ='"+ searchValue1 + "' ";
	  			}
	    		  
	    	  }
	    	  
      hql = hql +"  order by auditing asc ,disId desc";	
	    	  
	    	  //查询条件
	    	  
	    	  search_parameter="&where_search="+ where_search+"&like="+like+"&where_value="+en_where_value;
	    	  
	    	  pageModel = new PageModel();
	    	  
	    	  pageModel=this.getCommonService().findPage(hql, parem, currentPage, pageSize, "DissertationSearchAuditing1.action",search_parameter);
			
			
			
			return SUCCESS;
		}
		
		
		/***************Search审核列表*****************/		
		public String searchSelf() throws Exception {
			// TODO Auto-generated method stub
			String hql="from Dissertation";
			
			 String[] parem = null;
	    	  
	    	  String  search_parameter = "";
	    	  String en_where_value="";
	    	  
	    	  //
	    	  String searchValue1=where_value;
	    	  //
				HttpServletRequest request = ServletActionContext.getRequest();
				where_value=new String(request.getParameter("where_value").getBytes("ISO-8859-1"),"UTF-8");
				//
     if(!"".equals(where_value)&&where_value!=null){
	    		  
	    		  en_where_value=java.net.URLEncoder.encode(where_value, "utf-8");//URL编码转换
	    		  System.out.println("++++-- "+where_value);
	    		  
	    		  if (like.equals("like")) {
	    			  hql = hql + "  where " + where_search + " like '%"+ searchValue1 + "%' ";
	  				//hql = hql + "  and sc." + where_search + " like '%"+ searchValue1 + "%' ";
	  			} else {
	  				hql = hql + "  where " + where_search + " ='"+ searchValue1 + "' ";
	  				//hql = hql + "  and sc." + where_search + " ='"+ searchValue1 + "' ";
	  			}
	    		  
	    	  }
	    	  
     hql = hql +"  order by auditing asc ,disId desc";	
	    	  
	    	  //查询条件
	    	  
	    	  search_parameter="&where_search="+ where_search+"&like="+like+"&where_value="+en_where_value;
	    	  
	    	  pageModel = new PageModel();
	    	  
	    	  pageModel=this.getCommonService().findPage(hql, parem, currentPage, pageSize, "DissertationSearchSelf.action",search_parameter);
		
			
			return SUCCESS;
		}
		
		
		   /***
	     *   inside 对内公布
	     */
		  public String inside() throws Exception{
				 teacher = (Teacher)ActionContext.getContext().getSession().get(TEACHER_SESSION_KEY);

	    	  
			  dissertation=(Dissertation)this.getCommonService().findByIntId(disId, "gdut.jmxywz.been.Dissertation");
	    	  //将信息审核为对院内公布 ，即设置auditing为1；
			 if(dissertation!=null){
				 dissertation.setAuditing("1");
				 dissertation.setTeacherByAssessor(teacher);
			  boolean bl=this.getCommonService().updateObject(dissertation);
			   if(bl){  
			  return SUCCESS;
			   }
			   return "error";
			 }
			 return "error";
		  }
		  
		
	    /***
	     *   outside 对外公布
	     */
	    public String outside() throws Exception{
			 teacher = (Teacher)ActionContext.getContext().getSession().get(TEACHER_SESSION_KEY);

	    	dissertation=(Dissertation)this.getCommonService().findByIntId(disId, "gdut.jmxywz.been.Dissertation");
	    	  //将信息审核为对院内公布 ，即设置auditing为1；
			 if(dissertation!=null){
				 dissertation.setAuditing("2");
				 dissertation.setTeacherByAssessor(teacher);

			  boolean bl=this.getCommonService().updateObject(dissertation);
			   if(bl){  
			  return SUCCESS;
			   }
			   return "error";
			 }
			 return "error";
		  }
		
		/***
		 * 
		 *    notAllow 不通过
		 */
	    public String notAllow() throws Exception{
			 teacher = (Teacher)ActionContext.getContext().getSession().get(TEACHER_SESSION_KEY);

	    	dissertation=(Dissertation)this.getCommonService().findByIntId(disId, "gdut.jmxywz.been.Dissertation");
	    	  //将信息审核为对院内公布 ，即设置auditing为1；
			 if(dissertation!=null){
				 dissertation.setAuditing("3");
				 dissertation.setTeacherByAssessor(teacher);

			  boolean bl=this.getCommonService().updateObject(dissertation);
			   if(bl){  
			  return SUCCESS;
			   }
			   return "error";
			 }
			 return "error";
		  }
		
	    
	    
		
		/***
		 * 
		 *    rollBack 未审核
		 */
	    public String rollBack() throws Exception{
			 teacher = (Teacher)ActionContext.getContext().getSession().get(TEACHER_SESSION_KEY);

	    	dissertation=(Dissertation)this.getCommonService().findByIntId(disId, "gdut.jmxywz.been.Dissertation");
	    	  //将信息审核为对院内公布 ，即设置auditing为1；
			 if(dissertation!=null){
				 dissertation.setAuditing("0");
				 dissertation.setTeacherByAssessor(teacher);

			  boolean bl=this.getCommonService().updateObject(dissertation);
			   if(bl){  
			  return SUCCESS;
			   }
			   return "error";
			 }
			 return "error";
	  	  }


        //导入文件
	    @SuppressWarnings("unchecked")
		public String importExcel() throws Exception {
			 teacher = (Teacher)ActionContext.getContext().getSession().get(TEACHER_SESSION_KEY);

	
	    	// TODO Auto-generated method stub
			if(excelFile==null)
			{
				return "error";
				}
					

	    	int count=0;
			try{
			FileInputStream fis=new FileInputStream(excelFile);
			jxl.Workbook jwb=Workbook.getWorkbook(fis);
			int sheets=jwb.getNumberOfSheets();
			for(int i=0;i<sheets;i++){
				Sheet rs=jwb.getSheet(i);
				int columnNum=rs.getColumns();
				int rowNum=rs.getRows();
				System.out.println("======="+rowNum+"----"+columnNum);
				if(rowNum<0&&columnNum!=27){
					System.out.println("--------------------导入格式不对----------------------");
					return "error";
				}
				Cell crl;
				for(int row=1;row<rowNum;row++){
					crl=rs.getCell(10, row);
//					String hql="from Dissertation stc where stc.isbn='"+crl.getContents()+"'";
//					List<Dissertation> aa=this.getCommonService().findListByHql(hql, null);
					

	                 boolean bl;
	             
//					if(aa.size()==0){//项目未存在
						
						dissertation=new Dissertation();
                        dissertation.setIsbn(crl.getContents().trim());
                        crl=rs.getCell(0,row);
                        dissertation.setTitle(crl.getContents().trim());
                        crl=rs.getCell(1,row);
                        dissertation.setPublication(crl.getContents().trim());
                        crl=rs.getCell(2,row);
                        dissertation.setPublishYear(crl.getContents().trim());
                        crl=rs.getCell(3,row);
                        dissertation.setAuthor1(crl.getContents().trim());
                        crl=rs.getCell(4,row);
                        dissertation.setAuthor2(crl.getContents().trim());
                        crl=rs.getCell(5,row);
                        dissertation.setAuthor3(crl.getContents().trim());
                        crl=rs.getCell(6,row);
                        dissertation.setRoll(crl.getContents().trim());
                        crl=rs.getCell(7,row);
                        dissertation.setIssue(crl.getContents().trim());
                        crl=rs.getCell(8,row);
                        dissertation.setDocumentCode(crl.getContents().trim());
                        crl=rs.getCell(9,row);
                        dissertation.setPage(crl.getContents().trim());
                        crl=rs.getCell(11,row);
                        dissertation.setIssn(crl.getContents().trim());
                        crl=rs.getCell(12,row);
                        dissertation.setPublishCn(crl.getContents().trim());
                        crl=rs.getCell(13,row);
                        dissertation.setSci(crl.getContents().trim());
                        crl=rs.getCell(14,row);
                        dissertation.setEi(crl.getContents().trim());
                        crl=rs.getCell(15,row);
                        dissertation.setIstp(crl.getContents().trim());
                        crl=rs.getCell(16,row);
                        dissertation.setCorePeriodical(crl.getContents().trim());
                        crl=rs.getCell(17,row);
                        dissertation.setCatalog(crl.getContents().trim());
                        crl=rs.getCell(18,row);
                        dissertation.setType(crl.getContents().trim());
                        crl=rs.getCell(19,row);
                        dissertation.setIntergral(crl.getContents().trim());
                        crl=rs.getCell(20,row);
                        dissertation.setCn(crl.getContents().trim());
                        crl=rs.getCell(21,row);
                        dissertation.setLocal(crl.getContents().trim());
                        crl=rs.getCell(22,row);
                        dissertation.setFullTextCopy(crl.getContents().trim());
                        crl=rs.getCell(23,row);
                        dissertation.setForeignPage(crl.getContents().trim());
                        crl=rs.getCell(24,row);
                        dissertation.setColloquium(crl.getContents().trim());
                        crl=rs.getCell(25,row);
                        dissertation.setSource(crl.getContents().trim());
                        crl=rs.getCell(26,row);
                        dissertation.setTo2author(crl.getContents().trim());
                        
                        dissertation.setTeacherByEditer(teacher);
                        dissertation.setAuditing("0");
						bl=this.getCommonService().saveObject(dissertation);//不存在该项目

						if(!bl){
							System.out.println("------------------存入数据库出错-------------------");
						}
						
						count++;
						
					}
					
//					if(aa.size()!=0){//项目已存在
//							
//						
//						
//						if(checkbox&&aa.get(0).getAuditing().equals("0")){//判断是否对已存在项目进行更新
//							//对已存在项目进行更新	
//							
//							dissertation=aa.get(0);
//							 dissertation.setIsbn(crl.getContents());
//		                        crl=rs.getCell(0,row);
//		                        dissertation.setTitle(crl.getContents());
//		                        crl=rs.getCell(1,row);
//		                        dissertation.setPublication(crl.getContents());
//		                        crl=rs.getCell(2,row);
//		                        dissertation.setPublishYear(crl.getContents());
//		                        crl=rs.getCell(3,row);
//		                        dissertation.setAuthor1(crl.getContents());
//		                        crl=rs.getCell(4,row);
//		                        dissertation.setAuthor2(crl.getContents());
//		                        crl=rs.getCell(5,row);
//		                        dissertation.setAuthor3(crl.getContents());
//		                        crl=rs.getCell(6,row);
//		                        dissertation.setRoll(crl.getContents());
//		                        crl=rs.getCell(7,row);
//		                        dissertation.setIssue(crl.getContents());
//		                        crl=rs.getCell(8,row);
//		                        dissertation.setDocumentCode(crl.getContents());
//		                        crl=rs.getCell(9,row);
//		                        dissertation.setPage(crl.getContents());
//		                        crl=rs.getCell(11,row);
//		                        dissertation.setIssn(crl.getContents());
//		                        crl=rs.getCell(12,row);
//		                        dissertation.setPublishCn(crl.getContents());
//		                        crl=rs.getCell(13,row);
//		                        dissertation.setSci(crl.getContents());
//		                        crl=rs.getCell(14,row);
//		                        dissertation.setEi(crl.getContents());
//		                        crl=rs.getCell(15,row);
//		                        dissertation.setIstp(crl.getContents());
//		                        crl=rs.getCell(16,row);
//		                        dissertation.setCorePeriodical(crl.getContents());
//		                        crl=rs.getCell(17,row);
//		                        dissertation.setCatalog(crl.getContents());
//		                        crl=rs.getCell(18,row);
//		                        dissertation.setType(crl.getContents());
//		                        crl=rs.getCell(19,row);
//		                        dissertation.setIntergral(crl.getContents());
//		                        crl=rs.getCell(20,row);
//		                        dissertation.setCn(crl.getContents());
//		                        crl=rs.getCell(21,row);
//		                        dissertation.setLocal(crl.getContents());
//		                        crl=rs.getCell(22,row);
//		                        dissertation.setFullTextCopy(crl.getContents());
//		                        crl=rs.getCell(23,row);
//		                        dissertation.setForeignPage(crl.getContents());
//		                        crl=rs.getCell(24,row);
//		                        dissertation.setColloquium(crl.getContents());
//		                        crl=rs.getCell(25,row);
//		                        dissertation.setSource(crl.getContents());
//		                        crl=rs.getCell(26,row);
//		                        dissertation.setTo2author(crl.getContents());
//		                        
//		                        
//		                        dissertation.setTeacherByEditer(teacher);
//		                        dissertation.setAuditing("0");
//							
//							bl=this.getCommonService().updateObject(dissertation);//对已存在该项目更新
//						
//							if(!bl){
//								System.out.println("------------------存入数据库出错-------------------");
//							}
//							
//							count++;
//						}
//						
//						else{
//							System.out.print("项目已存在，但不做更新");//不做任何更新
//						}
//						
//					}
					
					
					
					
//				}
			}
			System.out.println("=================一共导入数据数：================="+count);
			jwb.close();
			fis.close();
			}catch(Exception e){
				e.printStackTrace();
			}
			return SUCCESS;
		}
		
	    //管理员导出Excel
	    public void exportExcel() throws Exception {
	    	
	    	
	    	// TODO Auto-generated method stub
			try{
				String[] str=new String[]{"论文名称","刊物名称","出版年份","第一作者","第二作者","第三作者","卷号","期号","文献标识码",
						"页码范围","ISBN","ISSN",
						"国外发行","SCI《科学引文索引》","EI《工程索引》",
						"ISTP《科技会议录索引》","核心期刊（是/否）","统计源","学科门类","Intergral",
						"CN国内统一刊号",
						"地方刊号","全文转载","外刊","论文集（国内或国外）","课题（资助）来源","第二作者作为归属者","发布者",
						"审核状态（0==未审核，1==院内公开，2==对外公开,3==审核不通过）","审核信息"};
				List list;
				
					String hql="from Dissertation";
					list=this.getCommonService().findListByHql(hql, null);
				
				
				
				HttpServletResponse response=ServletActionContext.getResponse();
				response.reset();
				response.setContentType("application/vnd.ms-excel");
				response.setContentType("APPLICATION/OCTET-STREAM ");
				response.setHeader("Content-Disposition","attachment; filename="+java.net.URLEncoder.encode("科研论文.xls","UTF-8"));
				WritableWorkbook wwb=Workbook.createWorkbook(response.getOutputStream());
				WritableSheet sheet=wwb.createSheet("sheet1", 0);
				sheet.setColumnView(0, 20);
				sheet.setColumnView(1, 20);
				sheet.setColumnView(2, 20);
				sheet.setColumnView(3, 20);
				sheet.setColumnView(11, 20);
				Label label=null;
				for(int i=0;i<str.length;i++){
					label=new Label(i,0,str[i]);
					sheet.addCell(label);
				}
				for(int i=0;i<list.size();i++){
					dissertation=(Dissertation)list.get(i);
					
					label = new Label(0, i+1, dissertation.getTitle());
					sheet.addCell(label);
					label = new Label(1, i+1, dissertation.getPublication());
					sheet.addCell(label);
					label = new Label(2, i+1, new SimpleDateFormat("yyyy-MM-dd").format(dissertation.getPublishYear()));
					sheet.addCell(label);
					label = new Label(3, i+1, dissertation.getAuthor1());
					sheet.addCell(label);
					label = new Label(4, i+1, dissertation.getAuthor2());
					sheet.addCell(label);
					label = new Label(5, i+1, dissertation.getAuthor3());
					sheet.addCell(label);
					label = new Label(6, i+1, dissertation.getRoll());
					sheet.addCell(label);
					label = new Label(7, i+1, dissertation.getIssue());
					sheet.addCell(label);
					label = new Label(8, i+1, dissertation.getDocumentCode());
					sheet.addCell(label);
					label = new Label(9, i+1, dissertation.getPage());
					sheet.addCell(label);
					label = new Label(10, i+1, dissertation.getIsbn());
					sheet.addCell(label);
					label = new Label(11, i+1, dissertation.getIssn());
					sheet.addCell(label);
					label = new Label(12, i+1, dissertation.getPublishCn());
					sheet.addCell(label);
					label = new Label(13, i+1, dissertation.getSci());
					sheet.addCell(label);
					label = new Label(14, i+1, dissertation.getEi());
					sheet.addCell(label);
					label = new Label(15, i+1, dissertation.getIstp());
					sheet.addCell(label);
					label = new Label(16, i+1, dissertation.getCorePeriodical());
					sheet.addCell(label);
					label = new Label(17, i+1, dissertation.getCatalog());
					sheet.addCell(label);
					label = new Label(18, i+1, dissertation.getType());
					sheet.addCell(label);
					label = new Label(19, i+1, dissertation.getIntergral());
					sheet.addCell(label);
					label = new Label(20, i+1, dissertation.getCn());
					sheet.addCell(label);
					label = new Label(21, i+1, dissertation.getLocal());
					sheet.addCell(label);
					label = new Label(22, i+1, dissertation.getFullTextCopy());
					sheet.addCell(label);
					label = new Label(23, i+1, dissertation.getForeignPage());
					sheet.addCell(label);
					label = new Label(24, i+1, dissertation.getColloquium());
					sheet.addCell(label);
					label = new Label(25, i+1, dissertation.getSource());
					sheet.addCell(label);
					label = new Label(26, i+1, dissertation.getTo2author());
					sheet.addCell(label);
					label = new Label(27, i+1, dissertation.getTeacherByEditer().getTeacherName());
					sheet.addCell(label);
					
					label = new Label(28, i+1, dissertation.getAuditing());
					sheet.addCell(label);
//					label = new Label(11, i+1, dissertation.getAssessor().getTeacherName());
//					sheet.addCell(label);
					label = new Label(29, i+1, dissertation.getAssessorInfo());
					sheet.addCell(label);
				}
				wwb.write();
				wwb.close();
				
			}catch(Exception e){
				e.printStackTrace();
			}
	
		}
	    
	    //非管理员导出Excel
	 public void exportSelfExcel() throws Exception {
		 teacher = (Teacher)ActionContext.getContext().getSession().get(TEACHER_SESSION_KEY);


			String hql=" from Dissertation where teacherByEditer.teacherId="+teacher.getTeacherId();
	    	
			// TODO Auto-generated method stub
			try{
				String[] str=new String[]{"论文名称","刊物名称","出版年份","第一作者","第二作者","第三作者","卷号","期号","文献标识码",
						"页码范围","ISBN","ISSN",
						"国外发行","SCI《科学引文索引》","EI《工程索引》",
						"ISTP《科技会议录索引》","核心期刊（是/否）","统计源","学科门类","Intergral",
						"CN国内统一刊号",
						"地方刊号","全文转载","外刊","论文集（国内或国外）","课题（资助）来源","第二作者作为归属者","发布者",
						"审核状态（0==未审核，1==院内公开，2==对外公开,3==审核不通过）","审核信息"};
				List list;
				
				
					list=this.getCommonService().findListByHql(hql, null);
				
				
				
				HttpServletResponse response=ServletActionContext.getResponse();
				response.reset();
				response.setContentType("application/vnd.ms-excel");
				response.setContentType("APPLICATION/OCTET-STREAM ");
				response.setHeader("Content-Disposition","attachment; filename="+java.net.URLEncoder.encode("科研论文.xls","UTF-8"));
				WritableWorkbook wwb=Workbook.createWorkbook(response.getOutputStream());
				WritableSheet sheet=wwb.createSheet("sheet1", 0);
				sheet.setColumnView(0, 20);
				sheet.setColumnView(1, 20);
				sheet.setColumnView(2, 20);
				sheet.setColumnView(3, 20);
				sheet.setColumnView(11, 20);
				Label label=null;
				for(int i=0;i<str.length;i++){
					label=new Label(i,0,str[i]);
					sheet.addCell(label);
				}
				for(int i=0;i<list.size();i++){
					dissertation=(Dissertation)list.get(i);
					
					label = new Label(0, i+1, dissertation.getTitle());
					sheet.addCell(label);
					label = new Label(1, i+1, dissertation.getPublication());
					sheet.addCell(label);
					label = new Label(2, i+1, new SimpleDateFormat("yyyy-MM-dd").format(dissertation.getPublishYear()));
					sheet.addCell(label);
					label = new Label(3, i+1, dissertation.getAuthor1());
					sheet.addCell(label);
					label = new Label(4, i+1, dissertation.getAuthor2());
					sheet.addCell(label);
					label = new Label(5, i+1, dissertation.getAuthor3());
					sheet.addCell(label);
					label = new Label(6, i+1, dissertation.getRoll());
					sheet.addCell(label);
					label = new Label(7, i+1, dissertation.getIssue());
					sheet.addCell(label);
					label = new Label(8, i+1, dissertation.getDocumentCode());
					sheet.addCell(label);
					label = new Label(9, i+1, dissertation.getPage());
					sheet.addCell(label);
					label = new Label(10, i+1, dissertation.getIsbn());
					sheet.addCell(label);
					label = new Label(11, i+1, dissertation.getIssn());
					sheet.addCell(label);
					label = new Label(12, i+1, dissertation.getPublishCn());
					sheet.addCell(label);
					label = new Label(13, i+1, dissertation.getSci());
					sheet.addCell(label);
					label = new Label(14, i+1, dissertation.getEi());
					sheet.addCell(label);
					label = new Label(15, i+1, dissertation.getIstp());
					sheet.addCell(label);
					label = new Label(16, i+1, dissertation.getCorePeriodical());
					sheet.addCell(label);
					label = new Label(17, i+1, dissertation.getCatalog());
					sheet.addCell(label);
					label = new Label(18, i+1, dissertation.getType());
					sheet.addCell(label);
					label = new Label(19, i+1, dissertation.getIntergral());
					sheet.addCell(label);
					label = new Label(20, i+1, dissertation.getCn());
					sheet.addCell(label);
					label = new Label(21, i+1, dissertation.getLocal());
					sheet.addCell(label);
					label = new Label(22, i+1, dissertation.getFullTextCopy());
					sheet.addCell(label);
					label = new Label(23, i+1, dissertation.getForeignPage());
					sheet.addCell(label);
					label = new Label(24, i+1, dissertation.getColloquium());
					sheet.addCell(label);
					label = new Label(25, i+1, dissertation.getSource());
					sheet.addCell(label);
					label = new Label(26, i+1, dissertation.getTo2author());
					sheet.addCell(label);
					label = new Label(27, i+1, dissertation.getTeacherByEditer().getTeacherName());
					sheet.addCell(label);
					
					label = new Label(28, i+1, dissertation.getAuditing());
					sheet.addCell(label);
//					label = new Label(11, i+1, dissertation.getAssessor().getTeacherName());
//					sheet.addCell(label);
					label = new Label(29, i+1, dissertation.getAssessorInfo());
					sheet.addCell(label);
				}
				wwb.write();
				wwb.close();
				
			}catch(Exception e){
				e.printStackTrace();
			}
			
		}
	    
	    
	    
	    
	    
	    
		public Teacher getTeacher() {
			return teacher;
		}


		public void setTeacher(Teacher teacher) {
			this.teacher = teacher;
		}


		public Dissertation getDissertation() {
			return dissertation;
		}



		public void setDissertation(Dissertation dissertation) {
			this.dissertation = dissertation;
		}



		public PageModel getPageModel() {
			return pageModel;
		}



		public void setPageModel(PageModel pageModel) {
			this.pageModel = pageModel;
		}



		public int getDisId() {
			return disId;
		}



		public void setDisId(int disId) {
			this.disId = disId;
		}



		public int getCurrentPage() {
			return currentPage;
		}



		public void setCurrentPage(int currentPage) {
			this.currentPage = currentPage;
		}



		public int getPageSize() {
			return pageSize;
		}



		public void setPageSize(int pageSize) {
			this.pageSize = pageSize;
		}



		/*public String getSearchSelect() {
			return searchSelect;
		}



		public void setSearchSelect(String searchSelect) {
			this.searchSelect = searchSelect;
		}*/



		public String getLike() {
			return like;
		}



		public void setLike(String like) {
			this.like = like;
		}



		/*public String getSearchValue() {
			return searchValue;
		}



		public void setSearchValue(String searchValue) {
			this.searchValue = searchValue;
		}*/


		public List<String> getFiles_content() {
			return files_content;
		}


		public void setFiles_content(List<String> files_content) {
			this.files_content = files_content;
		}


		public List<File> getUpload_file() {
			return upload_file;
		}


		public void setUpload_file(List<File> upload_file) {
			this.upload_file = upload_file;
		}


		public List<String> getUpload_fileContentType() {
			return upload_fileContentType;
		}


		public void setUpload_fileContentType(List<String> upload_fileContentType) {
			this.upload_fileContentType = upload_fileContentType;
		}


		public List<String> getUpload_fileFileName() {
			return upload_fileFileName;
		}


		public void setUpload_fileFileName(List<String> upload_fileFileName) {
			this.upload_fileFileName = upload_fileFileName;
		}


		public String getSavePath() {
			return savePath;
		}


		public void setSavePath(String savePath) {
			this.savePath = savePath;
		}


		public List<DissertationFile> getDissertationFile() {
			return dissertationFile;
		}


		public void setDissertationFile(List<DissertationFile> dissertationFile) {
			this.dissertationFile = dissertationFile;
		}


		public File getExcelFile() {
			return excelFile;
		}


		public void setExcelFile(File excelFile) {
			this.excelFile = excelFile;
		}


		public String getExcelFileContentType() {
			return excelFileContentType;
		}


		public void setExcelFileContentType(String excelFileContentType) {
			this.excelFileContentType = excelFileContentType;
		}


		public boolean isCheckbox() {
			return checkbox;
		}


		public void setCheckbox(boolean checkbox) {
			this.checkbox = checkbox;
		}


		public String getNextPage() {
			return nextPage;
		}


		public void setNextPage(String nextPage) {
			this.nextPage = nextPage;
		}


		public String getWhere_search() {
			return where_search;
		}


		public void setWhere_search(String whereSearch) {
			where_search = whereSearch;
		}


		public String getWhere_value() {
			return where_value;
		}


		public void setWhere_value(String whereValue) {
			where_value = whereValue;
		}



	    
	    
	    
	
	    
	    
	    
	    
	    

		
		
		
		
		
		
		
	
}
